-- GENERATED SPELL FOR [Maws] --


function spell0_15571(pUnit, Event) --@Dark Water,Self--
pUnit:FullCastSpellOnTarget(25743,pUnit)
pUnit:RegisterEvent('Sorts_15571', 653, 1)
end

function spell1_15571(pUnit, Event) --@Enrage,Self--
pUnit:FullCastSpellOnTarget(19812,pUnit)
pUnit:RegisterEvent('Sorts_15571', 8345, 1)
end

function spell2_15571(pUnit, Event) --@Rampage,n/a--
pUnit:FullCastSpellOnTarget(25744,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_15571', 609, 1)
end

function Sorts_15571(pUnit, Event)
local choix_sorts_15571 = math.random(0, 2)
if choix_sorts_15571 == 0 then
pUnit:RegisterEvent('spell0_15571', 1, 1)
end
if choix_sorts_15571 == 1 then
pUnit:RegisterEvent('spell1_15571', 1, 1)
end
if choix_sorts_15571 == 2 then
pUnit:RegisterEvent('spell2_15571', 1, 1)
end
end

function mob15571_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_15571', math.random(1500, 3000), 1)
end

function mob15571_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob15571_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob15571_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(15571, 1, 'mob15571_Action')
RegisterUnitEvent(15571, 2, 'mob15571_Leave')
RegisterUnitEvent(15571, 3, 'mob15571_Kill')
RegisterUnitEvent(15571, 4, 'mob15571_Die')
